<!DOCTYPE html>
<html xmlns:th="http://www.thymeleaf.org">
<head th:include="common::common(title='资源列表')">
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" ></meta>
</head>
<script th:inline="javascript">
</script>
<body>

	<div class="x-body" id="app">
		<form class="layui-form" id="layui-form">
		<xblock>
	        <button id="backBtn" class="layui-btn layui-btn-sm" @click.prevent="goBack"><i class="layui-icon">&#xe65c;</i>返回</button>
	        <button id="saveBtn" lay-submit="" lay-filter="saveBtn" class="layui-btn layui-btn-sm" @click.prevent="doSave"><i class="layui-icon">&#xe60a;</i>保存</button>
	    </xblock>
	      <div class="layui-form-item">
	      	<input type="hidden" v-model="formData.id" th:value="${id}" id="id" name="id">
	      	<div class="layui-inline">
	      		<label class="layui-form-label">账号<span style="color: red;">&nbsp;*</span></label>
	      		<div class="layui-input-inline" style="width: 180px;">
			      <input type="text" v-model="formData.name" name="name" autocomplete="off" class="layui-input" lay-verify="required">
			    </div>
	      	</div>
	      	<div class="layui-inline">
	      		<label class="layui-form-label">邮箱<span style="color: red;">&nbsp;*</span></label>
	      		<div class="layui-input-inline" style="width: 180px;">
			      <input type="text" v-model="formData.email" name="email" autocomplete="off" class="layui-input" lay-verify="required|email">
			    </div>
	      	</div>
	      	<div class="layui-inline">
	      		<label class="layui-form-label">电话<span style="color: red;">&nbsp;*</span></label>
	      		<div class="layui-input-inline" style="width: 180px;">
			      <input type="text" v-model="formData.phone" name="phone" autocomplete="off" class="layui-input" lay-verify="required|phone" >
			    </div>
	      	</div>
	      </div>
	      <div class="layui-form-item">
	      	<div class="layui-inline">
	      		<label class="layui-form-label">昵称<span style="color: red;">&nbsp;*</span></label>
	      		<div class="layui-input-inline" style="width: 180px;">
			      <input type="text" v-model="formData.nickName" name="nickName" autocomplete="off" class="layui-input layui-input-sm" lay-verify="required">
			    </div>
	      	</div>
	      	<div class="layui-inline" v-if="!ifEdit">
	      		<label class="layui-form-label">密码<span style="color: red;">&nbsp;*</span></label>
	      		<div class="layui-input-inline" style="width: 180px;">
			      <input type="password" id="password" v-model="formData.password" name="password" autocomplete="off" class="layui-input" lay-verify="required">
			    </div>
	      	</div>
	      	<div class="layui-inline" v-if="!ifEdit">
	      		<label class="layui-form-label">确认密码<span style="color: red;">&nbsp;*</span></label>
	      		<div class="layui-input-inline" style="width: 180px;">
			      <input type="password" v-model="formData.repassword" name="repassword" autocomplete="off" class="layui-input" lay-verify="required|repassword">
			    </div>
	      	</div>
	      </div>
	      <div class="layui-form-item">
		    <label class="layui-form-label">状态<span style="color: red;">&nbsp;*</span></label>
		    <div class="layui-input-block">
		      <input type="radio" name="status" value="1" title="启用" lay-filter="status">
		      <input type="radio" name="status" value="0" title="禁用" lay-filter="status">
		    </div>
		  </div>
		  <div class="layui-form-item">
		    <label class="layui-form-label">权限</label>
		    <div class="layui-input-block">
		      <ul id="authTree"></ul>
		    </div>
		  </div>
      </form>
	</div>
	<script type="text/javascript" th:src="@{/js/basic/userinfo_add.js?v=1}"></script>
</body>
</html>